<template>
  <div class="custom-card">
    <div class="icon-container">
      <Icon :name="icon" :size="iconSize" :color="color" />
    </div>
    <div class="content">
      <div class="title">{{ title }}</div>
      <div class="description">{{ description }}</div>
    </div>
  </div>
</template>

<script setup>
import {Cell,Icon} from "vant";
const props = defineProps({
  title: String,
  icon: String,
  color: String,
  description: String,
  iconSize: {
    type: Number,
    default: 40
  }
});

</script>

<style scoped>
.custom-card {
  display: flex;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  width: calc(100% - 20px); /* 每个卡片占一半宽度，减去间距 */
  padding: 10px;
  height: 80px;
}

.icon-container {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.content {
  flex: 3;
  padding-left: 20px;
}

.title {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 8px;
}

.description {
  font-size: 14px;
  color: #666666;
}
</style>
